package com.hqyj.controller;

import com.github.pagehelper.PageInfo;
import com.hqyj.pojo.Employee;
import com.hqyj.service.EmployeeService;
import com.hqyj.service.JobService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.servlet.http.HttpServletRequest;
import java.util.HashMap;
import java.util.List;
/*
经理管理的模块
 */
@Controller
@RequestMapping("/ess")
public class EmployeeController {
    @Autowired
    private EmployeeService employeeService;

/*
查询所有的签到信息
 */
   /* @RequestMapping(value = "/selectByPrimaryKeySigninSignout01",method = RequestMethod.GET)
    public List<Employee> selectByPrimaryKeySigninSignout01(){
        return employeeService.selectByPrimaryKeySigninSignout();
    }*/
   /*
   跳到employee_list页面
    */
   @RequestMapping("/employee01_list")
   public String employee01_list(){
       return "employee/employee01_list";
   }

    @RequestMapping("/employee02")
    public String employee02(){
        return "employee/employee02";
    }
    /*
    查询某条签到信息
     */
    @RequestMapping(value="selectByEnumber01",method = RequestMethod.GET)
    @ResponseBody
    public HashMap<String, Object> selectByEnumber01(int eNumber){
       return employeeService.selectByEnumber(eNumber);
    }
    /*
    模糊查询签到信息
     */
    @RequestMapping(value = "selectBy01",method = RequestMethod.GET)
    @ResponseBody
    public HashMap<String, Object> selectBy01( Employee e){
        return employeeService.selectBy(e);
    }




}
